<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="{$app_path}{$static_path}/js/jquery.min.js"></script>
<link href="{$app_path}{$static_path}/css/login-style.css" rel='stylesheet' type='text/css' />
</head>
<script type="text/javascript">
$("#optsendkey").click(function(){
	alert(2);
    $("#SendkeyDialog").dialog('open');
});
$("#buttonSendkey").click(function(){
	if($.trim($("#keyId").val()).length==0){
		$("#rdseguperrors").text("key不能为空");
		return false;
	}
	if($.trim($("#todomainId").val()).length==0){
		$("#rdseguperrors").text("topdomain不能为空");
		return false;
	}
	if($.trim($("#signId").val()).length==0){
		$("#rdseguperrors").text("sign不能为空");
		return false;
	}
	$.ajax({
		url : $("#sendkeyegupformid").attr("action"),
		data:$("#sendkeyegupformid").serialize(),
		dataType:'json',
		success : function(data) {
				$("#SendkeyDialog").dialog('close');
				$('#SendkeyDialog').datagrid('reload');
		},error:function(a,b,c){
			 jQuery.messager.alert('错误提示:','系统异常');
		}
	});
	
});
</script>
<body>
<div class="easyui-panel" style="padding:5px;">
	<br/>
	平台短信配置参数
	</div><br/><br/>
	<div class="tabledivclasss">
	<table cellspacing="0" cellpadding="0" border="1">
	<tr>
	<td width="160px">key</td>
	<td width="160px"topdomain</td>
	<td  width="160px">sign</td>
	<td  width="160px">操作</td>
	</tr>
	<tr>
	<td>{$send.key}</td>
	<td>{$send.todomain}</td>
	<td>{$send.sign}</td>
	<td><a href="#" id="optsendkey">编辑</a></td>
	</tr>
	</table>
	</div>
    
    <div id="SendkeyDialog" class="easyui-window" title="编辑" data-options="iconCls:'icon-save',closed:true" style="width:280px;height:200px;padding:10px;">
     <form  method="post" id="sendkeyegupformid" action="{$app_path}{:U('Admin/Sendkey/update')}">
		<span style="color: red;" id="rdseguperrors"></span>
		<br/>
			Key：<input type="text" name="key" id="keyId" value=""/><br/>
			Key：<input type="text" name="todomain" id="todomainId"  value=""/><br/>
			Key：<input type="text" name="sign" id="signId"  value=""/><br/>
			<input type="button" value="提交" id="buttonSendkey"/>
		</form>
    </div>
    
</body>
</html>
